<body>

<!-- Header -->
<div id="header">
    <div class="container">

        <!-- Logo -->
        <div id="logo">
            <h1><a href="#">胖洋葱种植园</a></h1>
            <span>一个走在全栈厨师路上的PHPer的博客</span>
        </div>

        <!-- Nav -->
        <nav id="nav">
            <ul>
                <li ><a href="/">Homepage</a></li>
                <li <?= ($type == 1) ? 'class="active"' : '' ?>><a href="/phper">PHPer</a></li>
                <li <?= ($type == 2) ? 'class="active"' : '' ?>><a href="/thinking">Thinking</a></li>
                <li <?= ($type == 3) ? 'class="active"' : '' ?>><a href="/goodlife">GoodLife</a></li>
                <li <?= ($type == 4) ? 'class="active"' : '' ?>><a href="/about">About</a></li>
            </ul>
        </nav>
    </div>
</div>

<!-- Main -->
<div id="main">
    <div class="container">
        <div class="row">

            <!-- Content -->
            <div id="content" class="8u skel-cell-important">
                <section class="11u">
                    <ul class="style">
                        <?php foreach ($typeList as $essay) { ?>
                            <li>
                                <p><h4><?= $essay['title']?></h4>  </p>
                                <p class="posted">  <?=date("Y-m-d", $essay['publish_time'])?></p>
                                <?php if (!empty($essay['headimage'])) { ?>
                                <img src="<?= $essay['headimage']?>" alt="" style="width: 70px; height: 70px;"/>
                                <?php } ?>
                                <p class="text"><?= \Org\Util\String::msubstr($essay['pre_content'], 0, 100)?></p>
                            </li>
                        <?php } ?>
                    </ul>
                </section>
            </div>

            <include file="Common@Component:sider"/>
        </div>
    </div>
</div>

<include file="Common@Component:featured"/>
